org.eclipse.vtp.framework.databases.configurations
Class DatabaseCriteriaConfiguration

java.lang.Object
  extended by org.eclipse.vtp.framework.databases.configurations.DatabaseCriteriaConfiguration
All Implemented Interfaces:
IConfiguration, DatabaseConstants

public class DatabaseCriteriaConfiguration
extends java.lang.Object
implements IConfiguration, DatabaseConstants

A configuration for a database query criteria.

Author:
Lonnie Pryor

Field Summary
static int COMPARISON_EQUAL
          Compare for equality.
static int COMPARISON_GREATER_THAN
          Compare for greater than.
static int COMPARISON_GREATER_THAN_OR_EQUAL
          Compare for greater than or equality.
static int COMPARISON_LESS_THAN
          Compare for less than.
static int COMPARISON_LESS_THAN_OR_EQUAL
          Compare for less than or equality.
static int COMPARISON_NOT_EQUAL
          Compare for lack of equality.
static int TYPE_NONE
          No requirement exists for this criteria.
static int TYPE_STATIC
          Use a static value to match against.
static int TYPE_VARIABLE
          Use the value of a variable to match against.
 
Fields inherited from interface org.eclipse.vtp.framework.databases.configurations.DatabaseConstants
NAME_COLUMN, NAME_COMPARISON, NAME_CRITERIA, NAME_DATABASE, NAME_DRIVER, NAME_JDBC_DATABASE, NAME_JNDI_DATABASE, NAME_MAPPING, NAME_NAME, NAME_PASSWORD, NAME_QUERY, NAME_RESULT_CARDINALITY, NAME_RESULT_LIMIT, NAME_RESULT_NAME, NAME_RESULT_TYPE, NAME_TABLE, NAME_TIMEOUT, NAME_TYPE, NAME_URI, NAME_URL, NAME_USERNAME, NAME_VALUE, NAMESPACE_URI
 
Constructor Summary
DatabaseCriteriaConfiguration()
          Creates a new DatabaseCriteriaConfiguration.
 
Method Summary
 int getComparison()
          Returns the type of comparison to perform.
 java.lang.String getName()
          Returns the name of the field to map to.
 int getType()
          Returns the type of mapping to perform.
 java.lang.String getValue()
          Returns the value to use for the mapping.
 void load(org.w3c.dom.Element configurationElement)
          Loads the configuration information from the specified XML element.
 void save(org.w3c.dom.Element configurationElement)
          Saves the configuration information into the supplied XML element.
 void setComparison(int comparison)
          Sets the type of comparison to perform.
 void setName(java.lang.String name)
          Sets the name of the field to map to.
 void setType(int type)
          Sets the type of mapping to perform.
 void setValue(java.lang.String value)
          Sets the value to use for the mapping.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COMPARISON_EQUAL

public static final int COMPARISON_EQUAL
Compare for equality.

See Also:
Constant Field Values

COMPARISON_NOT_EQUAL

public static final int COMPARISON_NOT_EQUAL
Compare for lack of equality.

See Also:
Constant Field Values

COMPARISON_LESS_THAN

public static final int COMPARISON_LESS_THAN
Compare for less than.

See Also:
Constant Field Values

COMPARISON_LESS_THAN_OR_EQUAL

public static final int COMPARISON_LESS_THAN_OR_EQUAL
Compare for less than or equality.

See Also:
Constant Field Values

COMPARISON_GREATER_THAN

public static final int COMPARISON_GREATER_THAN
Compare for greater than.

See Also:
Constant Field Values

COMPARISON_GREATER_THAN_OR_EQUAL

public static final int COMPARISON_GREATER_THAN_OR_EQUAL
Compare for greater than or equality.

See Also:
Constant Field Values

TYPE_NONE

public static final int TYPE_NONE
No requirement exists for this criteria.

See Also:
Constant Field Values

TYPE_VARIABLE

public static final int TYPE_VARIABLE
Use the value of a variable to match against.

See Also:
Constant Field Values

TYPE_STATIC

public static final int TYPE_STATIC
Use a static value to match against.

See Also:
Constant Field Values
Constructor Detail

DatabaseCriteriaConfiguration

public DatabaseCriteriaConfiguration()
Creates a new DatabaseCriteriaConfiguration.

Method Detail

getName

public java.lang.String getName()
Returns the name of the field to map to.

Returns:
The name of the field to map to.

setName

public void setName(java.lang.String name)
Sets the name of the field to map to.

Parameters:
name - The name of the field to map to.

getComparison

public int getComparison()
Returns the type of comparison to perform.

Returns:
The type of comparison to perform.

setComparison

public void setComparison(int comparison)
Sets the type of comparison to perform.

Parameters:
comparison - The type of comparison to perform.

getType

public int getType()
Returns the type of mapping to perform.

Returns:
The type of mapping to perform.

setType

public void setType(int type)
Sets the type of mapping to perform.

Parameters:
type - The type of mapping to perform.

getValue

public java.lang.String getValue()
Returns the value to use for the mapping.

Returns:
The value to use for the mapping.

setValue

public void setValue(java.lang.String value)
Sets the value to use for the mapping.

Parameters:
value - The value to use for the mapping.

load

public void load(org.w3c.dom.Element configurationElement)
Description copied from interface: IConfiguration
Loads the configuration information from the specified XML element.

Specified by:
load in interface IConfiguration
Parameters:
configurationElement - The element to load the configuration from.

save

public void save(org.w3c.dom.Element configurationElement)
Description copied from interface: IConfiguration
Saves the configuration information into the supplied XML element.

Specified by:
save in interface IConfiguration
Parameters:
configurationElement - The element to save the configuration to.